Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[feature]Support DLQ, TTL,Delay message #929

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

GhostBoyBoy
Copy link
Contributor

@GhostBoyBoy GhostBoyBoy commented Jun 9, 2023

  1. Support DLQ, TTL
  2. Support vhost name (tenant/namespace) by '/' partition
  3. Add the admin api

Master Issue: #832,#861,#862,#863

Motivation

The current version does not support dead letter queues and message ttl, as well as delayed messages, which are often used in rabbitmq and we need to implement.

Modifications

1.For dead letter queue.
The queue binding parameter determines whether it is DLQ and uses the queue's own cursor to check for active consumers.
When there is an active consumer, it means that we do not need to control, when the active consumer is closed we need to start a task to detect, when there is no message to register to the listening queue, when awakened, first check whether there is an active consumer, if not, we need to route the message to the DLQ.
2.For TTL.
For DLQ, messages are routed to DLQ only after they expire. If they are not expired, a task countdown is registered and the time is up for detection

Verifying this change

  • Make sure that the change passes the CI checks.

(Please pick either of the following options)

This change is a trivial rework / code cleanup without any test coverage.

(or)

This change is already covered by existing tests, such as (please describe tests).

(or)

This change added tests and can be verified as follows:

(example:)

  • Added integration tests for end-to-end deployment with large payloads (10MB)
  • Extended integration test for recovery after broker failure

Does this pull request potentially affect one of the following parts:

If yes was chosen, please highlight the changes

  • Dependencies (does it add or upgrade a dependency): (yes / no)
  • The public API: (yes / no)
  • The schema: (yes / no / don't know)
  • The default values of configurations: (yes / no)
  • The wire protocol: (yes / no)
  • The rest endpoints: (yes / no)
  • The admin cli options: (yes / no)
  • Anything that affects deployment: (yes / no / don't know)

Documentation

Check the box below.

Need to update docs?

  • doc-required

    (If you need help on updating docs, create a doc issue)

  • no-need-doc

    (Please explain why)

  • doc

    (If this PR contains doc changes)

2. support vhost name (tenant/namespace) by '/' partition
3. Add the admin api
@CLAassistant
Copy link

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.


明一飞 seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account.
You have signed the CLA already but the status is still pending? Let us recheck it.

@github-actions github-actions bot added the no-need-doc This pr does not need any document label Jun 9, 2023
@gaoran10
Copy link
Collaborator

Great work! Can we split this PR?

@GhostBoyBoy
Copy link
Contributor Author

Great work! Can we split this PR?

I'm happy to do it

@GhostBoyBoy
Copy link
Contributor Author

Split into 4 parts

  1. Tenant configuration is supported.
  2. TTL message expiration processing is supported. (Dead letter delivery not included)
  3. Support dead letter queue.
  4. Delay the queue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
no-need-doc This pr does not need any document
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants